import request from '@/utils/request'

// 查询课程任务列表
export function listCoursetask(query) {
  return request({
    url: '/edu/coursetask/list',
    method: 'get',
    params: query
  })
}

// 查询课程任务详细
export function getCoursetask(id) {
  return request({
    url: '/edu/coursetask/' + id,
    method: 'get'
  })
}

// 新增课程任务
export function addCoursetask(data) {
  return request({
    url: '/edu/coursetask',
    method: 'post',
    data: data
  })
}

// 修改课程任务
export function updateCoursetask(data) {
  return request({
    url: '/edu/coursetask',
    method: 'put',
    data: data
  })
}

// 删除课程任务
export function delCoursetask(id) {
  return request({
    url: '/edu/coursetask/' + id,
    method: 'delete'
  })
}
